function chkform(){
	var unameV = o("uname").value,pwdV = o("pwd").value,verifycodeV = o("verifycode").value;
	if(zeai.str_len(unameV) < 2 || zeai.str_len(unameV)>20){
		zeai.msg('请输入登录帐号',uname);
		return false;
	}
	if(zeai.str_len(pwdV)<6 || zeai.str_len(pwdV)>20){
		zeai.msg('密码长度请控制在6～20字节之间',pwd);
		return false;
	}
	if(!zeai.ifint(verifycodeV,"0-9","4")){
		zeai.msg('请输入正确的验证码',verifycode);
		return false;
	}
	zeai.ajax({url:'./login'+zeai.extname,data:{submitok:'ajax_submit',uname:unameV,pwd:pwdV,v:verifycodeV,loginkind:o("loginkind").value}},function(e){var rs=zeai.jsoneval(e);
		if (rs.flag == 1){zeai.openurl(rs.url);}else{
			zeai.msg(rs.msg,{time:5,focus:verifycode});
			return false;
		}		
	});
	return false;
}
function ReloadCode(){o('gylverify' ).src='../sub/authcode.php?dt='+new Date().getTime();}
function otherlogin(){
	zeai.ajax({url:'m_login'+zeai.ajxext+'submitok=ajax_weixinlogin'},function(e){var rs=zeai.jsoneval(e);
		if(rs.flag==1){
			zeai.openurl(rs.url);
		}else{
			zeai.msg(rs.msg,{time:5});	
		}
	});
}
/*pcewmlogin*/
var gyl;
function zeai_cn__ewmLogin(type){
	if(type=='ewmlogin'){
		zeai.ajax({url:'login'+zeai.ajxext+'submitok=ajax_logincode'},function(e){var rs=zeai.jsoneval(e);
			if(rs.flag==1){
				clearInterval(gyl);
				supdes=zeai.div({obj:o('loginewm'),title:'微信扫码登录',w:450,h:500,fn:function(){clearInterval(gyl);}  });
				Z_e___A___I__c___N.src=rs.url;
				gyl= setInterval(function(){chk_logincode(rs.logincode,gyl);},3000);
			}else{
				zeai.msg(rs.msg);	
			}
		});
	}else if(type=='mobadm'){
		zeai.div({obj:o('mobadm'),title:'手机端后台',w:450,h:500});
	}
	function chk_logincode(logincode,gyl){
		zeai.ajax({url:'login'+zeai.ajxext+'submitok=ajax_ewmlogin&logincode='+logincode},function(e){var rs=zeai.jsoneval(e);
			if(rs.flag==1){
				zeai.openurl(rs.url);
			}else if(rs.flag==2){
				clearInterval(gyl);
				zeai.alert(rs.msg);
			}
		});
	}
}